@use 'sass:map';
@use 'sass:color';
@use '@angular/material' as mat;

@mixin color($config-or-theme) {
  $config: mat.get-color-config($config-or-theme);
  $background: map.get($config, background);
  $foreground: map.get($config, foreground);
  $primary: map.get($config, primary);
  $accent: map.get($config, accent);
  
  pac-widget-kpi {
    .ngm-kpi--trend {
      .ngm-object-number--value {
        font-size: 1rem;
        line-height: 1rem;
      }
      // .ngm-object-number--short-unit {
      //   font-size: 0.5rem;
      //   line-height: 0.5rem;
      // }
    }

    .ngm-object-number--short-unit {
      font-size: 1rem;
      line-height: 1rem;
    }
    .ngm-object-number--unit {
      justify-content: flex-start;
      align-content: flex-start;
    }
  
    // .ngm-kpi--reference {
    //   .ngm-object-number--unit {
    //     align-items: flex-start;
    //     font-size: 0.5rem;
    //     line-height: 0.5rem;
    //   }
    // }
  }
  
}

@mixin density($config-or-theme) {
}

@mixin typography($config-or-theme) {
}

@mixin theme($theme) {
  $color: mat.get-color-config($theme);
  $density: mat.get-density-config($theme);
  $typography: mat.get-typography-config($theme);

  @if $color != null {
    @include color($color);
  }
  @if $density != null {
    @include density($density);
  }
  @if $typography != null {
    @include typography($typography);
  }
}
